//[
Streem
[androidJvm]
interface Streem
Types
Name | Summary |
---|---|
AppTheme | [androidJvm] data class AppTheme(val primaryColor: String) |
Companion | [androidJvm] object Companion |
Configuration | [androidJvm] data class Configuration(val application: Application, val appId: CharSequence, val environment: Streem.Environment? = null, val tokenRefresher: TokenRefresher? = null) |
Country | [androidJvm] data class Country(val callingCode: String, val isoCode: String, val countryName: String) |
CreateInvitationResult | [androidJvm] sealed class CreateInvitationResult |
Environment | [androidJvm] class Environment |
InvitationDialogResult | [androidJvm] sealed class InvitationDialogResult |
InvitationType | [androidJvm] enum InvitationType : Enum<Streem.InvitationType> |
LinkType | [androidJvm] sealed class LinkType |
LoginCompletionResult | [androidJvm] sealed class LoginCompletionResult |
LoginInvitationResult | [androidJvm] sealed class LoginInvitationResult |
ParticipantRequest | [androidJvm] data class ParticipantRequest(val remoteUserId: String, val sessionConfig: Streem.SessionConfig) : Parcelable |
SessionConfig | [androidJvm] class SessionConfig : Parcelable |
StreemIdentity | [androidJvm] data class StreemIdentity(val name: String, val companySid: String, val companyName: String?, val avatarUrl: String, val isExpert: Boolean) |
StreemInvitation | [androidJvm] data class StreemInvitation(val invitationSid: String, val invitationCode: String, val url: String, val fromName: String, val fromRemoteId: String? = null, val fromPhotoURL: String? = null, val fromCompanyCode: String? = null, val fromCompanyName: String? = null, val fromCompanyLogoURL: String? = null, val toName: String, val toPhone: String? = null, val expiresAt: Date?, val invitationType: Streem.InvitationType? = null) : Serializable |
SupportedCountriesResult | [androidJvm] sealed class SupportedCountriesResult |
User | [androidJvm] sealed class User |
UserProfile | [androidJvm] data class UserProfile(val user: Streem.User, val expert: Boolean) |
Functions
Name | Summary |
---|---|
createInvitation | [androidJvm] abstract fun createInvitation(toUserName: String, referenceId: String? = null, integrationId: String? = null, phone: String? = null, invitationType: Streem.InvitationType, resultCallback: (Streem.CreateInvitationResult) -> Unit) Creates an invitation to streem, and returns invitation information for display to the user. |
getExitCode | [androidJvm] abstract fun getExitCode(requestCode: Int, resultCode: Int, data: Intent?): String? Returns the exit code from the Streem experience if requestCode represents an Activity that was started by the Streem SDK. Otherwise returns null . This method should be called from Activity.onActivityResult or Fragment.onActivityResult. It should only be called when resultCode == RESULT_OK in order to avoid calling Streem.get() before the Streem SDK has been initialized. |
getMissingPermissions | [androidJvm] abstract fun getMissingPermissions(context: Context): List<String> Returns a list of the permissions required to use the Streem SDK that are not presently granted. |
getRequiredPermissions | [androidJvm] abstract fun getRequiredPermissions(): List<String> Returns a list of the permissions required to use the Streem SDK. |
getSupportedCountries | [androidJvm] abstract fun getSupportedCountries(resultCallback: (Streem.SupportedCountriesResult) -> Unit) Returns a list of countries supported by the Streem service. Typically this is used before calling createInvitation when submitting a phone param, which must include a country code. First call getSupportedCountries, then use the countries list to populate a form field for country code, and/or validate user-entered phone numbers before submitting them phone number to createInvitation. |
login | [androidJvm] abstract fun login(userProfile: Streem.UserProfile, resultCallback: (Streem.LoginCompletionResult) -> Unit? = null) Logs in the current user to the Streem SDK. New users are automatically provisioned on first use. Existing users will have their profile information updated to match userProfile. [androidJvm] abstract fun login(invitationUri: Uri, isExpert: Boolean, resultCallback: (Streem.LoginInvitationResult) -> Unit) Logs in the user invited via the invitation Uri and passes back invitation details (the inviter’s name, company, avatar image URL, etc.) through resultCallback. With the StreemInvitation received in resultCallback, launch the Streem experience using StartStreemFromInvitation. [androidJvm] abstract fun login(invitationCode: String, isExpert: Boolean, resultCallback: (Streem.LoginInvitationResult) -> Unit) Logs in the user invited via the invitation code and passes back invitation details (the inviter’s name, company, avatar image URL, etc.) through resultCallback. With the StreemInvitation received in resultCallback, launch the Streem experience using StartStreemFromInvitation. |
logout | [androidJvm] abstract fun logout() Logs out the user that was last logged in via login. This should be used whenever the user logs out from the app. |
parseUri | [androidJvm] abstract fun parseUri(uri: Uri?): Streem.LinkType? Determines if a uri targets Streem and returns the relevant LinkType. |
startStreemActivity | [androidJvm] @MainThread abstract fun @MainThread abstract fun @MainThread abstract fun startStreemActivity(currentFragment: Fragment, localParticipantSessionConfig: Streem.SessionConfig, remoteParticipant: Streem.ParticipantRequest? = null, errorCallback: (Throwable) -> Unit? = null) @MainThread abstract fun Opens a room with the participants in a new full-screen Activity. [androidJvm] @MainThread abstract fun Opens or joins a room with the current invitation in a new full-screen Activity. [androidJvm] @MainThread abstract fun Opens or joins a room with an invitation code in a new full-screen Activity. |
startStreemActivityForInvitation | [androidJvm] @MainThread abstract fun Opens or joins a room with the current invitation in a new full-screen Activity. [androidJvm] @MainThread abstract fun Opens or joins a room with an invitation code in a new full-screen Activity. |
startStreemToRemoteUser | [androidJvm] @MainThread abstract fun startStreemToRemoteUser(currentActivity: Activity, remoteUserId: String, companyCode: String, referenceId: String? = null, integrationId: String? = null) Opens a room with the participants in a new full-screen Activity by way of the lobby. |
Properties
Name | Summary |
---|---|
appTheme | [androidJvm] abstract var appTheme: Streem.AppTheme Sets the optional app theme with a primary color |